<template>
  <div class="footer_bar wrap">
    <router-link to="/index" class="item">
      <div class="img"></div>
      <div class="text">首页</div>
    </router-link>
    <router-link to="/shop" class="item">
      <div class="img"></div>
      <div class="text">分类</div>
    </router-link>
    <router-link to="/shopList" class="item">
      <div class="img"></div>
      <div class="text">商品</div>
    </router-link>
    <router-link to="/car" class="item">
      <div class="img"></div>
      <div class="text">购物车</div>
    </router-link>
    <!-- <router-link to="" class="item">
        <div class="img"></div>
        <div class="text">附近店铺</div>
      </router-link> -->
    <router-link to="/My" class="item">
      <div class="img"></div>
      <div class="text">我的</div>
    </router-link>
    <div class="bottom"></div>
  </div>
</template>

<script>
export default {};
</script>

<style lang="scss" scoped>
.footer_bar {
  position: fixed;
  z-index: 10;
  bottom: 0;
  background: #fff;
  height: 65px;
  width: 100%;
  display: flex;
  bottom: -1px;
  justify-content: space-between;
  box-shadow: 0px -5px 5px #f4f3f3;
  box-sizing: border-box;
  padding-bottom: 7px;

  .item {
    width: 20%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    color: #9c9c9c;

    .img {
      width: 33px;
      height: 30px;
      background-position-x: -24px;
      transform: scale(0.5);
    }

    > .text {
      margin-top: -3px;
    }

    &:nth-of-type(1) .img {
      background: url(../assets/imgs/footer_icon2.png) -24px -25px;
    }

    &:nth-of-type(2) .img {
      background: url(../assets/imgs/footer_icon2.png) -24px -104px;
    }

    &:nth-of-type(3) .img {
      background: url(../assets/imgs/footer_icon2.png) -24px -104px;
    }

    &:nth-of-type(4) .img {
      background: url(../assets/imgs/footer_icon2.png) -24px -186px;
    }

    &:nth-of-type(5) .img {
      background: url(../assets/imgs/footer_icon2.png) -24px -345px;
    }

    &.con {
      color: #000;

      .img {
        background-position-x: -104px;
        background-repeat: no-repeat;
      }
    }
  }
}
</style>